package cn.may.entity;

import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import com.alibaba.excel.annotation.format.NumberFormat;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

/**
 * @author May
 * @date 2020/10/30 15:13
 * @desc
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class Student {
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @ExcelProperty("编号")
    @ColumnWidth(30)
    private String id;
    @ColumnWidth(10)
    @ExcelProperty("姓名")
    private String name;
    @ExcelProperty("年龄")
    private Integer age;
    @ExcelProperty("性别")
    private String sex;
    @ExcelProperty("生日")
    @ColumnWidth(15)
    @DateTimeFormat("yyyy-MM-dd")
    private String birthday;
    @ExcelProperty("存款")
    @ColumnWidth(15)
//    @NumberFormat("#.##")
    private Double money;
}
